<template>
  <div class="ant-store-coupons" v-if="data" @click="handlerClick">
    <div class="tag">{{data.name}}</div>
    <div class="coupons-hd">
      <p class="coupons-name">{{data.money}}元优惠券</p>
    </div>
    <div class="coupons-bd">
      <p class="coupons-amount">满{{data.condition}}可用</p>
      <p class="coupons-btn" >立即领取</p>
    </div>
  </div>
</template>

<script>
  import {
    getDate
  } from '@/utils/index'
  export default {
    props: ['data'],
    computed: {

    },
    methods: {
      handlerClick(e) {
        console.log(e)
        this.$emit("click", this.data)
      }
    },
    mounted() {},
  };

</script>

<style lang="less">
  .ant-store-coupons {
    background: #FFF1EE;
    border: 1rpx solid #FFC9BC;
    border-radius: 5px;
    position: relative;
    padding: 23px 27px 13px 18px;
    display: inline-block;
    margin-right: 15px;

    .tag {
      position: absolute;
      left: 0;
      top: 0;
      font-size: 8px;
      line-height: 16px;
      background: #F8B351;
      color: #fff;
      padding: 0 5px;
    }

    .coupons-hd {
      margin-bottom: 6px;
    }

    .coupons-name {
      font-size: 14px;
      color: #EE7559;
      line-height: 1em;
    }

    .coupons-bd {
      display: flex;
    }

    .coupons-amount {
      font-size: 10px;
      color: #A0A0A0;
      line-height: 1em;
    }

    .coupons-btn {
      margin-left: 20px;
      font-size: 10px;
      color: #EF7D63;
      line-height: 1em;
    }
  }

</style>
